-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: remove auto self-contained build for .NET 8 beanstalk deployments #847
Conversation
24c3d67
to
8ba5823
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #847 +/- ##
==========================================
+ Coverage 61.93% 62.39% +0.45%
==========================================
Files 279 279
Lines 10850 10900 +50
Branches 1496 1513 +17
==========================================
+ Hits 6720 6801 +81
+ Misses 3598 3563 -35
- Partials 532 536 +4 ☔ View full report in Codecov by Sentry. |
Add a platform version check for the version that added .NET8. If a user is redeploying we shouldn't break them. |
8d2d690
to
ca7d45d
Compare
ca7d45d
to
1ccd396
Compare
if (beanstalkPlatformSettingValueSplit?.Length != 3) | ||
throw new InvalidElasticBeanstalkPlatformException(DeployToolErrorCode.InvalidElasticBeanstalkPlatform, $"The selected Elastic Beanstalk platform version '{beanstalkPlatformSettingValue}' is invalid."); | ||
var beanstalkPlatformName = beanstalkPlatformSettingValueSplit[1]; | ||
if (!Version.TryParse(beanstalkPlatformSettingValueSplit[2], out var beanstalkPlatformVersion)) | ||
throw new InvalidElasticBeanstalkPlatformException(DeployToolErrorCode.InvalidElasticBeanstalkPlatform, $"The selected Elastic Beanstalk platform version '{beanstalkPlatformSettingValue}' is invalid."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this format part of Elastic Beanstalk's "contract"? I would hate to penalize users by throwing an exception if EB ever changed the convention of these strings.
I'm wondering if it'd be safer to just proceed if we fail to parse, and possibly let the deployment fail, since users could then set Self Contained Build
themselves to proceed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved assuming you address Alex's feedback
Issue #, if available:
DOTNET-7212
Description of changes:
In order to support deploying .NET8 apps on Beanstalk prior to Beanstalk adding .NET8 support, we had to force .NET8 apps to be self-contained in order to allow for Beanstalk support. Beanstalk has since added .NET8 support, so this PR removes this restriction to allow .NET8 apps to be deployed to Beanstalk not as self-contained apps.
This PR also improves the sorting of Beanstalk platforms to show the latest .NET versions first.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.